package cn.rxls.community.controller;



import cn.rxls.community.dto.complaintFeedback.AddComplaintFeedbackDTO;
import cn.rxls.community.result.Result;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import cn.rxls.community.entity.ComplaintFeedback;
import cn.rxls.community.service.ComplaintFeedbackService;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;
import javax.validation.Valid;
import java.io.Serializable;
import java.util.List;

/**
 * 投诉反馈(ComplaintFeedback)表
 *
 */
@RestController
@RequestMapping("complaintFeedback")
@Validated
public class ComplaintFeedbackController   {
    /**
     * 服务对象
     */
    @Resource
    private ComplaintFeedbackService complaintFeedbackService;

    /**
     * 新增投诉反馈
     *
     * @param dto 参数对象
     * @return 是否成功
     */
    @PostMapping("/add")
    public Result<Boolean> selectAll(@Valid @RequestBody AddComplaintFeedbackDTO dto) {
        return Result.success(complaintFeedbackService.addComplaintFeedback(dto));
    }


}

